<template>
  <div class="container">
    <!-- 修改弹框 -->
    <el-dialog title="修改学科" :visible.sync="dialogFormVisible" width="30%">
      <el-form>
        <el-form-item label="学科名称" :label-width="formLabelWidth">
          <el-input
            ref="dataForm"
            v-model="form.name"
            autocomplete="off"
            placeholder="大数据"
          ></el-input>
        </el-form-item>
        <el-form-item label="是否显示" :label-width="formLabelWidth">
          <el-switch v-model="value" active-color="#13ce66"> </el-switch>
        </el-form-item>
      </el-form>
      <div slot="footer" class="dialog-footer">
        <el-button @click="dialogFormVisible = false">取 消</el-button>
        <el-button type="primary">确 定</el-button>
      </div>
    </el-dialog>
    <!-- /修改弹框 -->
  </div>
</template>

<script>
export default {
  name: 'SubjectsAdd',
  props: {
    // titleInfo: {
    //   type: Object,
    //   required: true
    // },
    formBase: {
      type: Array,
      required: true
    }
  },
  data() {
    return {
      dialogFormVisible: false,
      formLabelWidth: '70px',
      value: true,
      form: {
        name: '',
        region: '',
        date1: '',
        date2: '',
        delivery: false,
        type: [],
        resource: '',
        desc: ''
      }
    }
  },
  methods: {
    async dialogForm(id) {
      this.dialogFormVisible = true

      console.log(this.formBase)
    }
  }
}
</script>
<style scoped lang="less"></style>
